{switch name="type"}
	{case value="readonly"}
		<input type="text" class="form-control" name="{$field}" id="{$field}" value="{$value}" readonly>
	{/case}
	{case value="text"}
		<input type="text" class="form-control" name="{$field}" id="{$field}" value="{$value}">
	{/case}
	{case value="password"}
		<input type="password" class="form-control" name="{$field}" id="{$field}" value="{$value}">
	{/case}
	{case value="textarea"}
	<textarea class="form-control" name="{$field}" id="{$field}">{$value}</textarea>
	{/case}
	{case value="select"}
	<select class="form-control" name="{$field}" id="{$field}" style="width:auto;">
		{volist name="option" id="item"}
		<option value="{$key}" {if condition="$key eq $value"}selected{/if}>{$item}</option>
		{/volist}
	</select>
	{/case}
	{case value="datetime"}
	<div class="input-group">
		<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
		<input type="text" class="form-control {$field}" id="{$field}" data-date-format="yyyy-mm-dd hh:ii" readonly="">
	</div>
	<script type="text/javascript">
		//datepicker
		$('.{$field}').datetimepicker({
		  format: 'yyyy-dd-mm hh:ii:ss'
		});
	</script>
	{/case}
	{case value="image"}
	<div id="picker-box">
		<div id="picker_{$field}" class="picker_button">上传图片</div>
		<input type="hidden" name="{$field}" id="{$field}" value="{$value}">
		<div id="fileList" class="upload-file-list-info" style="width:280px;"></div>
	</div>
	<script type="text/javascript">
		uploadsize =  2;
		$(function(){
			$(".picker_button").SentUploader({
					fileNumLimit:1,
					uploadEvents: {
						uploadComplete:function(file){}
					},
					hiddenName: '{$field}',
					hiddenValType:1,
					fileSingleSizeLimit:uploadsize*1024*1024,
					closeX:true
				},
				{
					fileType: 'service',
					filename : 'images',
				});
		});
	</script>
	{/case}
	{case value="images"}
	<div id="picker-box">
		<div id="picker_{$field}" class="picker_button">上传多图</div>
		<input type="hidden" name="{$field}" id="{$field}" value="{$value}">
		<div id="fileList" class="upload-file-list-info" style="width:280px;"></div>
	</div>
	<script type="text/javascript">
		uploadsize =  2;
		$(function(){
			$(".picker_button").SentUploader({
					uploadEvents: {
						uploadComplete:function(file){}
					},
					hiddenName: '{$field}',
					hiddenValType:1,
					fileSingleSizeLimit:uploadsize*1024*1024,
					closeX:true
				},
				{
					fileType: 'service',
					filename : 'images',
				});
		});
	</script>
	{/case}
	{case value="attach"}
	<div id="picker-box">
		<div id="picker_{$field}" class="picker_button">上传文件</div>
		<input type="hidden" name="{$field}" id="{$field}" value="{$value}">
		<div id="fileList" class="upload-file-list-info" style="width:280px;"></div>
	</div>
	<script type="text/javascript">
		uploadsize =  2;
		$(function(){
			$(".picker_button").SentUploader({
					uploadEvents: {
						uploadComplete:function(file){}
					},
					hiddenName: '{$field}',
					hiddenValType:1,
					fileSingleSizeLimit:uploadsize*1024*1024,
					closeX:true
				},
				{
					fileType: 'service',
					filename : 'attach',
				});
		});
	</script>
	{/case}
	{case value="editor"}
	<textarea name="{$field}" id="{$field}">{$value}</textarea>
	<script type="text/javascript">
	serverUrl = "{:U('Admin/File/ueditor')}";
	{if condition="$option['type'] eq 'all' || $option['type'] eq ''"}
	var ue = UE.getEditor("{$field}",{
		serverUrl         : serverUrl,
		initialFrameWidth : "100%",
		initialFrameHeight : "300"
	});
	{elseif condition="$option['type'] eq 'mini'"/}
	var ue = UE.getEditor("{$field}",{
		toolbars: [
	        ['source', 'bold', 'italic', 'underline', 'fontborder', 'strikethrough', '|','link', 'unlink', '|','simpleupload',]
	    ],
		initialFrameWidth : "100%",
		initialFrameHeight : "120"
	});
	{/if}
	</script>
	{/case}
{/switch}